-- CALC_MASTER_WRECKAGE_BONUS

-- 计算魔法师残骸奖励
return function(user, bonusArg)
    -- 60%概率：获得【光元素结晶】或【暗元素结晶】
    -- 20%概率：获得【魔法太妃糖】
    -- 15%概率：获得【橡木魔棒】
    -- 5%概率：获得【黄岑木魔棒】或【胡桃木魔棒】
    local arr = {
        {["class_id"] =  7042, ["count"] =  2, ["ratio"] =  300, },   -- 光元素结晶
        {["class_id"] =  7043, ["count"] =  2, ["ratio"] =  300, },   -- 暗元素结晶
        {["class_id"] =  7056, ["count"] =  1, ["ratio"] =  200, },   -- 魔法太妃糖
        {["class_id"] =  8055, ["count"] =  1, ["ratio"] =  150, },   -- 榆木魔棒
        {["class_id"] =  8056, ["count"] =  1, ["ratio"] =  25,  },   -- 黄岑木魔棒
        {["class_id"] =  8057, ["count"] =  1, ["ratio"] =  25,  },   -- 胡桃木魔棒
    };

    local seed  = DungeonM.getRandSeed("CALC_MASTER_WRECKAGE_BONUS");

    local info = fetchElemBySeed(arr, seed);

    local classId = info["class_id"];
    local count   = info["count"];
    
    local ret = {
        { 1, classId, count, },
    };

    return ret;
end